package com.hirelinfo.dto.faculty;


import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;
import javax.validation.constraints.Min;
import javax.validation.constraints.NotNull;

import org.hibernate.annotations.Generated;
import org.hibernate.validator.constraints.Length;
import org.hibernate.validator.constraints.NotBlank;
import org.hibernate.validator.constraints.NotEmpty;

@Entity
@Table(name="USER_DETAILS")
public class User {

	private int id;
	
	private String name;
	private String password;
	private String city;
	private String contact;
	
	@NotNull(message="Student ID should not be Empty.")
	@Min(value=2,message="Student ID is not Valid.")
	@Id
	public int getId() {
		return id;
	}

	
	@NotEmpty(message="Name should not be blank")
	@NotBlank(message="Name should be Required")
	public String getName() {
		return name;
	}
	
	@NotEmpty(message="Password should not be blank")
	@NotBlank(message="Password should be blank")
	@Length(min=4,message="At Least 4 digit Password must be Required.")
	public String getPassword() {
		return password;
	}
	@NotEmpty(message="City should not be blank")
	@NotBlank(message="City should be Required")
	public String getCity() {
		return city;
	}
	
	@NotEmpty(message="Contact should not blank.")
	@Length(min=10,max=10,message="lenght should be 10 digit")
	public String getContact() {
		return contact;
	}
	public void setId(int id) {
		this.id = id;
	}
	public void setName(String name) {
		this.name = name;
	}
	public void setPassword(String password) {
		this.password = password;
	}
	public void setCity(String city) {
		this.city = city;
	}
	public void setContact(String contact) {
		this.contact = contact;
	}
	
}
